home *** CD-ROM | disk | FTP | other *** search
- ----------------------------------------------------------
-
- | TECHINFO.TXT - Explanations and technical info about SSG |
-
- |----------------------------------------------------------|
-
- | by Chuck Lantz and Tom Darby for CS 257 - OOD, |
-
- | Carleton College, Northfield, MN 55057. |
-
- ----------------------------------------------------------
-
-
-
- --------------------------------------------------------------------------
-
-
-
- ----------
-
- | CONTENTS |
-
- ----------
-
-
-
- I. Tech/design info
-
- i. Objectives
-
- ii. Objects
-
- iii. Speed considerations
-
- II. The Game
-
- i. The plot and object of the game
-
- ii. Menu control
-
- iii. Player control
-
- III. Closing comments
-
-
-
- --------------------------------------------------------------------------
-
-
-
- -------------------
-
- | I.i. - OBJECTIVES |
-
- -------------------
-
-
-
- Spiffy Spaceguy (SSG) was written with the following criteria in mind:
-
-
-
- 1) Implementation of Object-Oriented Design techniques
-
- 2) A game that's fun to play
-
- 3) A game that's fast and will run on a 486 class machine
-
-
-
- --------------------------------------------------------------------------
-
-
-
- -----------------
-
- | I.ii. - OBJECTS |
-
- -----------------
-
-
-
- Here are the basic objects in the game (NOTE: /,-, and \ denote an
-
- inheritance):
-
-
-
- Graphics objects
-
- ----------------
-
- Bitmap
-
- Sprite
-
- Font
-
-
-
- Menu objects
-
- ------------
-
- Main Menu
-
- /
-
- Menu -|
-
- \
-
- Options Menu
-
-
-
- Ship objects
-
- ------------
-
- AI ships
-
- /
-
- Ship -|- Player ship
-
- |\
-
- | Shrapnel
-
- \
-
- Booms
-
-
-
- --------------------------------------------------------------------------
-
-
-
- -------------------------------
-
- | I.iii. - SPEED CONSIDERATIONS |
-
- -------------------------------
-
-
-
- Because of our third criterion (speed), we had to make some concessions to
-
- the first objective. Specifically, we used the "Spawn_Sprite" routines, and
-
- did not break the AI ship routine into several other derived classes.
-
-
-
- Why? Well, we decided the fastest way to do collision detection was through
-
- the use of a large "AI ship array" rather than splitting it up into several
-
- smaller arrays. This is faster as we do not have to traverse several arrays
-
- and compare each element to each element in each array, but rather simply
-
- have to traverse one single array. As a result, we called weapons and
-
- enemies AI ships and gave them values that allowed them to interact correctly.
-
- This was MUCH faster than our original multiple derivation idea. Adding
-
- other ships to the AI ship class is quite simple, and only involves a case
-
- statement.
-
-
-
- Next, we note that all the images are also stored in one array. Originally,
-
- we had the system dynamically allocate storage for the image of each
-
- ship as it was created, and deallocate as destroyed, but that turned out to
-
- be quite slow and sucked up a large amount of RAM when a large number of
-
- sprites were on the screen. Thus, the array was created and the images are
-
- accessed by way of an enumerated type which IS stored by each object.
-
- (Thus we have a sort of pointer to an image stored rather than the image
-
- itself.)
-
-
-
- Finally, the spawn sprite issue. Since we needed classes to create large
-
- numbers of objects from different classes, we needed some method for them
-
- to "spawn" (or create) a new object quickly and efficiently. The
-
- "Spawn_Sprite" functions were our answer. They are simply inline functions
-
- that declare a object to be "active" and give it some important starting
-
- information. Note that these functions are overloaded (and have default
-
- values for object specific information) and thus allow us to call "one
-
- function" to activate any object type.
-
-
-
- In this current version we do not have the system check for speed and
-
- decide on how many sprites should be active (this will be added later),
-
- so we have the OPTIONS menu which allows you to reduce the number of objects
-
- on the screen on slower machines.
-
-
-
- --------------------------------------------------------------------------
-
-
-
- -----------------------------------------
-
- | II.i. - THE PLOT AND OBJECT OF THE GAME |
-
- -----------------------------------------
-
-
-
- ( NOTE: Spiffy Spaceguy I is also known as Spaceman Spiff and was changed
-
- for copyright reasons. This game is based upon SSG I which was created
-
- by Tom Darby for CS117. )
-
-
-
- THE PLOT
-
- --------
-
- When we last saw our hero, he was returning home to Earth after vanquishing
-
- the evil Gorkon Armada and foiling their plot to destroy the universe as
-
- we know it. In anticipation of a hero's welcome (and party), Spiffy Spaceguy
-
- was pouring his first celebritory martini, envisioning the grand gala
-
- reception that awaited him.
-
-
-
- SUDDENLY, a panicked voice crackled over the radio. Stirred but unshaken
-
- (ha ha), Spiffy Spaceguy turned to the controls of his ship and listened...
-
-
-
- "MAYDAY, MAYDAY! We are under attack by the K'irjnarr fleet! We can't stop
-
- them, there's--there's too many--anyone, help! Come in! Stop them before
-
- they reach Earth! No, no! Oh, the humanit-- *KSHZZZZZZT*
-
-
-
- Cursing, Spiffy Spaceguy threw his martini glass out the window (ha ha)
-
- and punched in the hyperdrive. Like it or not, he knew that he was
-
- the only pilot good enough to stop the massive K'irjnarr fleet and save
-
- Earth. With a blinding flash, Spiffy Spaceguy's ship leapt forward,
-
- disappearing into the vast emptiness that is space...
-
-
-
- His celebration will have to wait.
-
-
-
- THE OBJECTIVE
-
- -------------
-
- When the game begins, Spiffy Spaceguy has just caught up to the evil
-
- K'irjnaar's first wave of ships headed towards Earth. Spiff must fight his way
-
- through them in an attempt to help decimate the fleet's multitudes and
-
- save Earth. He will have to make it through countless onslaughts of
-
- K'irjnaar ships and mine fields to ultimately save the universe.
-
-
-
- --------------------------------------------------------------------------
-
-
-
- -----------------------
-
- | II.ii. - MENU CONTROL |
-
- -----------------------
-
-
-
- When the game starts, the "Squeal! Production" sign will appear. If you press
-
- a key then, you will advance to the menu. If you don't, you will enter the
-
- introduction. (If you choose to see the introduction, hit a key to make
-
- the next section of text scroll up.)
-
-
-
- Once the title screen appears, hit a key and the main menu will show up.
-
- Press up and down to move the spaceship next to the option you want to select
-
- and press enter. These options are:
-
-
-
- NEW GAME - Begins a new game from WAVE 1.
-
- CONTINUE - If you died, this will start you from the wave you died on, but
-
- will set your score to 0.
-
- OPTIONS - This goes to the Options menu
-
- QUIT - Quits the game
-
-
-
- If you choose to go to the options menu, you will see a list of these settings:
-
-
-
- MAX SHRAPNEL - The maximum amount of shrapnel that can be on the screen
-
- at any one time.
-
- BOOM SHRAPNEL - The amount of shrapnel launched when a ship explodes
-
- MAX BOOMS - The maximum number of "booms" (oof, thud, blammo, etc..)
-
- that can be on the screen at any time.
-
- MAX SPRITES - The maximum number of gunshots and AIs that can be on the
-
- screen at any time.
-
- STARS PER LEVEL - The number of stars at each scroller level
-
- SOUND SETUP - Currently not implemented.
-
-
-
- Press the left and right arrow keys to change these settings, and press
-
- ESC when you are done.
-
-
-
- --------------------------------------------------------------------------
-
-
-
- --------------------------
-
- | II.iii. - PLAYER CONTROL |
-
- --------------------------
-
-
-
- You control Spiffy Spaceguy's ship via the mouse. Pressing the left
-
- mouse button will cause this ship's weapon to fire, and the right mouse
-
- button selects which weapon you use. Pressing the mouse button will cause
-
- the newly selected weapon to flash just under the status bar on the game
-
- screen.
-
-
-
- Other keys of interest:
-
-
-
- P - Pauses the game.
-
- ESC - Aborts your current game.
-
-
-
- --------------------------------------------------------------------------
-
-
-
- ------------------------
-
- | IV. - CLOSING COMMENTS |
-
- ------------------------
-
-
-
- Chuck and Tom put a great deal of effort into this project, but had a great
-
- time doing it. We hope you enjoy the game!!!
-
-
-
-
-